-
Notifications
You must be signed in to change notification settings - Fork 4k
ARROW-11038: [Rust] Removed unused trait and Result. #9017
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
rust/arrow/src/array/builder.rs
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change was motivated by T not really requiring ArrowPrimitiveType, only ArrowNativeType, and is required for a major simplification on the Buillders, #9019
Codecov Report
@@ Coverage Diff @@
## master #9017 +/- ##
==========================================
- Coverage 82.87% 82.87% -0.01%
==========================================
Files 201 201
Lines 49739 49733 -6
==========================================
- Hits 41220 41215 -5
+ Misses 8519 8518 -1
Continue to review full report at Codecov.
|
Dandandan
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, LGTM 👍 I believe there are also quite some other places returning unneeded Results.
| /// and resizes the buffer as needed. | ||
| /// | ||
| /// The values of the newly added elements are undefined. | ||
| /// The values of the newly added elements are 0. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe T::default()
| pub type UInt64BufferBuilder = BufferBuilder<UInt64Type>; | ||
| pub type Float32BufferBuilder = BufferBuilder<Float32Type>; | ||
| pub type Float64BufferBuilder = BufferBuilder<Float64Type>; | ||
| pub type Int8BufferBuilder = BufferBuilder<i8>; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 This is a nice simplification
|
I also merged from master and ran the tests locally to make sure this didn't logically conflict. Everything was good to go! |
|
This is a nice cleanup -- thank you @jorgecarleitao |
This PR removes an unused trait and associated API that returns
Result<()>for infalible implementationsBoth of these are historical artifacts derived from using
io::write, which was abandoned because these operations are infalible.